function  grad = gradient2s(func, x)
    syms x1 x2;
    grad = subs([diff(func, x1);...
                 diff(func, x2)], {x1, x2}, x);

end

